﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace syh876.com.Models
{
    public class RegisterModel
    {
        [Required]
        [Display(Name = "用户名")]
        public string UserName { get; set; }

        [Required]
        [StringLength(100, ErrorMessage = "密码最小必须是6位字母或数字", MinimumLength = 6)]
        [DataType(DataType.Password)]
        [Display(Name = "密码")]
        public string UserPwd { get; set; }

        [DataType(DataType.Password)]
        [Display(Name = "确认密码")]
        [Compare("UserPwd", ErrorMessage = "密码不一致")]
        public string ConfirmUserPwd { get; set; }

        [Display(Name = "公司名称")]
        public string CompanyName { get; set; }


        [Display(Name = "联系人")]

        public string RealName { get; set; }

        [Display(Name = "手机号码")]
        //[RegularExpression(@"(\(\d{3}\)|\d{3}-)?\d{8}", ErrorMessage = "手机号码格式不正确")]
        public string Mobile { get; set; }

        //[Required]
        [Display(Name = "邮箱")]
        //[RegularExpression(@"\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*", ErrorMessage = "邮箱格式不正确")]
        public string Email { get; set; }


        [Display(Name = "QQ")]
        public string QQ { get; set; }
        [Display(Name = "QQ的appid")]
        public string AppId { get; set; }
        

        [Display(Name = "省")]
        public int ProvinceId { get; set; }

        [Display(Name = "市")]
        public int CityId { get; set; }

        [Display(Name = "区")]
        public int AreaId { get; set; }

        [Display(Name = "买卖身份")]
        public int Nature { get; set; }

        [Display(Name = "性别")]
        public int Sex { get; set; }
    }
}